using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;

namespace Deepcode.Flux.Core.Systems.Security
{
	/// <summary>
	/// Represents a single permission group
	/// </summary>
	public class PermissionGroup
	{
		private string _GroupName = "";
		private ArrayList _Permissions = new ArrayList();

		/// <summary>
		/// Gets the name of this permission group
		/// </summary>
		public string GroupName { get { return _GroupName; } }

		/// <summary>
		/// Gets the array of permission codes contained within this group
		/// </summary>
		public Permission[] Permissions
		{
			get
			{
				return _Permissions.ToArray(typeof(Permission)) as Permission[];
			}
		}

		public PermissionGroup(string groupname, ArrayList childPermissionItems)
		{
			_GroupName = groupname;
			_Permissions = childPermissionItems;
		}
	}
}
